<!--新闻详情页头部-->
<template>
    <div class="header">
        <van-nav-bar :title="picshufflingFigure.articleSource" left-text="返回" left-arrow style="background-color: #409EFF;"
              @click-left="onClick"       >
            <template #right>
                <van-icon name="search" size="18" @click="jump"/>
            </template>
        </van-nav-bar>
    </div>
</template>

<script>
    import {newsDetails} from "../api/api";

    export default {
        name: "DetailTop.vue",
        data(){
            return {
                picshufflingFigure: [],

            }
        },
        methods:{
            onClick() {
                this.$router.go(-1);
            },
            jump(){
                this.$router.push("/search");
            }
        },
        created() {
            // 轮播图
            newsDetails(this.$route.query.articleId).then(res => {
                // console.log(res)
                this.picshufflingFigure = res.data

            })
        },
    }
</script>

<style scoped lang="less">
    .header {
        width: 100%;
        height: 45px;
        margin-top: 0px;
        background-color: #409EFF;
        font-size: 28px;
        line-height: 45px;
    }

    /deep/ .van-nav-bar__title {
        color: #FFFFFF;
    }

    /deep/ .van-icon {
        font-size: 24px !important;
    }

    /deep/ .van-icon {
        color: #FFFFFF;
        font-size: 24px;
    }

    /deep/ .van-nav-bar__text {
        color: #FFFFFF;

    }
</style>